#include<iostream>

using namespace std;

int main(){
	int x;
	cin>>x;
	
	int l=0, r=x, ans=-1;
	while(l <= r) {
        int m = l + (r - l) / 2;
        if ((long long)m*m <= x) {
            ans = m;
			l = m + 1;
        } else{
            r = m - 1;
        }
    }
    cout<<ans<<endl; 
    return 0;
} 
